<!DOCTYPE html>
<html lang="en">
    <head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Vue Template</title>
</head>
<body>
    <div id="app">
        <cpn></cpn>
        <cpn>
            <template slot-scope='slot'>
                <span>{{slot.data.join(' - ')}}</span>
            </template>
        </cpn>
    </div>
    <template id="cpn">
        <div>
            <slot v-bind:data = "language">
                <ul>
                    <li v-for="item in language">{{item}}</li>
                </ul>
            </slot>
        </div>
    </template>
<script src="../js/vue.js"></script>
<script>
    const app = new Vue({
        el: '#app',
        data: {
            message: 'hello Vue!'
        },
        components: {
            cpn: {
                template: "#cpn",
                data() {
                    return {
                        language: ['java','javaScript','C++','C#','Swift','python','php']
                    }
                }
            }
        }
    })
</script>
</body>
</html>